package com.hwua.service.Impl;

import com.hwua.dao.IProCategoryDao;
import com.hwua.dao.Impl.ProCategoryDaoImpl;
import com.hwua.entity.ProductCategory;
import com.hwua.service.IProductService;

import java.util.List;

public class ProductServiceImpl implements IProductService {
    private IProCategoryDao proCategoryDao=new ProCategoryDaoImpl();

    @Override
    public List<ProductCategory> queryList() throws Exception {
        return proCategoryDao.queryAll();
    }

    @Override
    public int getCount(int id) throws Exception {
        return proCategoryDao.getCount(id);
    }

    @Override
    public List<ProductCategory> query() throws Exception {
        return proCategoryDao.query();
    }

    @Override
    public List<ProductCategory> queryByID(int parent_id) throws Exception {
        return proCategoryDao.queryByID(parent_id);
    }

    @Override
    public ProductCategory queryBySelfID(int id) throws Exception {
        return proCategoryDao.queryBySelfID(id);
    }
}
